package cn.da.shuai.cool.finance.model;

import cn.da.shuai.cool.common.entity.EntityBase;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.time.LocalDateTime;

@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("cool_budget_audit")
public class CoolBudgetAudit extends EntityBase {

    @TableField("budget_id")
    private Long budgetId;

    @TableField("action")
    private String action; // CREATE, UPDATE, APPROVE, REJECT, ACTUAL_RECORD

    @TableField("action_time")
    private LocalDateTime actionTime;

    @TableField("user_id")
    private Long userId;

    @TableField("user_name")
    private String userName;

    @TableField("old_amount")
    private BigDecimal oldAmount;

    @TableField("new_amount")
    private BigDecimal newAmount;

    @TableField("old_status")
    private String oldStatus;

    @TableField("new_status")
    private String newStatus;

    @TableField("reason")
    private String reason;

    @TableField("ip_address")
    private String ipAddress;

    @TableField("details")
    private String details;
}